package com.wjy;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.domain.EntityScan;
import org.springframework.boot.builder.SpringApplicationBuilder;
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.security.config.annotation.web.configuration.EnableWebSecurity;
import org.springframework.transaction.annotation.EnableTransactionManagement;

import springfox.documentation.swagger2.annotations.EnableSwagger2;

@ComponentScan(value = "com.wjy")
@EntityScan(value = "com.wjy")
@MapperScan(value = "com.wjy")
@EnableSwagger2
@EnableWebSecurity
@EnableTransactionManagement
@SpringBootApplication
public class RBACApplication extends SpringBootServletInitializer {

	public static void main(String[] args) {
		SpringApplication.run(RBACApplication.class, args);
	}

	@Override
	protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
		return builder.sources(RBACApplication.class);
	}

}
